package com.vitabuybuy.tv.dto;


import androidx.databinding.BaseObservable;
import androidx.databinding.Bindable;

import com.vitabuybuy.tv.BR;
import com.vitabuybuy.tv.utils.LanaugeUtils;

import java.util.List;

/**
 * 作者：SimGa
 * 日期：2020/12/3
 * 时间：12:03
 * 包名：com.vitabuybuy.tv.dto
 */
public class LoginInfoDto extends BaseObservable {

    public LoginInfoDto() {
    }

    /**
     * birthday : 2020-12-03
     * loginTime : 2020-12-03 13:20:50
     * gender : 男
     * phone : 15622129194
     * createTime : 2020-12-03 13:20:50
     * userSign : eJw1jssKwjAURP8layk3aZM2XepCEINFK1RwIySt1xchaY0i-ru11eXMnAPzIuVyE5mHRWdITjnnDAAmQ3s3juSERUDG7PX5YC3qnksAEk4hY*OC2txarHEQRPrnsenj1OsG4mI3A-VcZCtXXHDrpOen4DutXKlYJYM7ztdV2HcAsf7ZLV6-jwQIKSmT6fsDcegx2g__
     * nickname : SimGa
     * id : 67
     * avatar : http://106.55.47.138/attachment/png/4165/508_27169.png
     * email : 542362080@qq.com
     * enabled : true
     */
    @Bindable
    private String birthday;
    private String loginTime;
    @Bindable
    private String gender;
    private String phone;
    private String createTime;
    private String executorStatus;
    private String userSign;
    @Bindable
    private String nickname;
    @Bindable
    private String address;
    private int id;
    @Bindable
    private String avatar;
    @Bindable
    private String email;
    private boolean enabled;

    private int favoritesQuantity;
    private int attentionQuantity;
    private int  footprintQuantity;
    private int  couponQuantity;
    private RegionBean region;
    private boolean executorEnable;

    public boolean isExecutorEnable() {
        return executorEnable;
    }

    public void setExecutorEnable(boolean executorEnable) {
        this.executorEnable = executorEnable;
    }

    public String getExecutorStatus() {
        return executorStatus;
    }

    public void setExecutorStatus(String executorStatus) {
        this.executorStatus = executorStatus;
    }

    public int getAttentionQuantity() {
        return attentionQuantity;
    }

    public void setAttentionQuantity(int attentionQuantity) {
        this.attentionQuantity = attentionQuantity;
    }

    public int getFootprintQuantity() {
        return footprintQuantity;
    }

    public void setFootprintQuantity(int footprintQuantity) {
        this.footprintQuantity = footprintQuantity;
    }

    public int getCouponQuantity() {
        return couponQuantity;
    }

    public void setCouponQuantity(int couponQuantity) {
        this.couponQuantity = couponQuantity;
    }

    public int getFavoritesQuantity() {
        return favoritesQuantity;
    }

    public void setFavoritesQuantity(int favoritesQuantity) {
        this.favoritesQuantity = favoritesQuantity;
    }

    private List<RegionBean> regionList;

    public RegionBean getRegion() {
        return region;
    }

    public void setRegion(RegionBean region) {
        this.region = region;
    }

    public List<RegionBean> getRegionList() {
        return regionList;
    }

    public void setRegionList(List<RegionBean> regionList) {
        this.regionList = regionList;
    }

    public static class RegionBean {
        public RegionBean(int id) {
            this.id = id;
        }
        public RegionBean() {}

        private int id;
        private String name;

        public int getId() {
            return id;
        }

        public void setId(int id) {
            this.id = id;
        }

        public String getName() {
            return LanaugeUtils.returnStrByLocation(name);
        }

        public void setName(String name) {
            this.name = name;
        }
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getBirthday() {
        return birthday;
    }

    public void setBirthday(String birthday) {
        this.birthday = birthday;
        notifyPropertyChanged(BR.birthday);
    }

    public String getLoginTime() {
        return loginTime;
    }

    public void setLoginTime(String loginTime) {
        this.loginTime = loginTime;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
        notifyPropertyChanged(BR.gender);
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime;
    }

    public String getUserSign() {
        return userSign;
    }

    public void setUserSign(String userSign) {
        this.userSign = userSign;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
        notifyPropertyChanged(BR.nickname);
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
        notifyPropertyChanged(BR.avatar);
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
        notifyPropertyChanged(BR.email);
    }

    public boolean isEnabled() {
        return enabled;
    }

    public void setEnabled(boolean enabled) {
        this.enabled = enabled;
    }

    public LoginInfoDto(String nickname, String avatar,String phone, String email, String gender, String birthday,RegionBean region) {
        this.nickname = nickname;
        this.avatar = avatar;
        this.phone = phone;
        this.email = email;
        this.gender = gender;
        this.birthday = birthday;
        this.region = region;
    }
}
